// homeindex 首页
// classify 分类
// jingxi 惊喜
// shopcart 购物车
// my 我的
import { lazy } from "react"
import Home from "../views/Home"
import { WapHomeO,AppsO ,FilterO,CartO,ManagerO} from '@react-vant/icons';
const routes=[
    {
        path:'/home',
        component:Home,
        children:[
            {
                path:"/home/homeindex",
                component:lazy(()=>import('../views/home/HomeIndex')),
                title:"首页",
                icon:<WapHomeO  />
            },
            {
                path:"/home/classify",
                component:lazy(()=>import('../views/home/Classify')),
                title:"分类",
                icon:<AppsO  />
            },
            {
                path:"/home/jingxi",
                component:lazy(()=>import('../views/home/Jingxi')),
                title:"惊喜",
                icon:<FilterO  />
            },
            {
                path:"/home/shopCart",
                component:lazy(()=>import('../views/home/ShopCart')),
                title:"购物车",
                icon:<CartO  />
            },
            {
                path:"/home/my",
                component:lazy(()=>import('../views/home/My')),
                title:"我的",
                icon:<ManagerO  />
            },
        ]
    },
    {
        path:'/',
        redirect: '/home/homeindex',  // 重定向:重新指向其它path,会改变网址
    }
]
export default routes